<route type="home" lang="json">
  {
    "style": { 
      "navigationStyle": "custom",
      "enablePullDownRefresh": false,
      "app-plus": {
        "bounce": "none"
      }
    }
  }
</route>
<template>
  <view class="wrapper">
    <view class="summary">
      <view class="title">
       <wd-img :width="60" :height="60" mode="'scaleToFill" :src="logo" />
        我是市监助手，很高兴见到你！
      </view>
      <view class="desc">
        我可以帮助你答疑市场监督相关政策法规，请把您的问题告诉我把~
      </view>
     <wd-button @click="openConversation">开启会话</wd-button>
    </view>
  </view>
</template>

<script setup lang="ts">
  import { onLoad } from '@dcloudio/uni-app';
  import logo from '@/static/logo.png';
  
  onLoad((option) => {
    console.log(option);
  })
  
  const openConversation = () => {
    uni.redirectTo({
      url: `/pages/chat/index`,
    })
  }
</script>

<style scoped lang="scss">
  .wrapper {
    display: flex;
    flex-direction: column;
    justify-content: center;
    width: 100%;
    height: 100vh;
    .summary {
      box-sizing: border-box;
      text-align: left;
      width: 100%;
      padding: 0 34px;
      .title {
        width: 100%;
        font-size: 18px;
        font-weight: 500;
        line-height: 24px;
        color: #000;
        display: flex;
        flex-direction: column;
        gap: 14px;
      }
      .desc {
        width: 100%;
        margin: 14px 0 24px;
        font-size: 14px;
        line-height: 24px;
        color: #404040;
      }
    }
  }
</style>
